 /**
   * Copyright 2014 Viettel Telecom. All rights reserved.
   * VIETTEL PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
   */
 package com.viettel.core.bussiness.cms; 
import java.util.List; 

import org.springframework.beans.factory.annotation.Autowired; 

import com.viettel.core.exceptions.BusinessException; 
import com.viettel.core.exceptions.DataAccessException; 
import com.viettel.core.dao.cms.AnswersQuestionDAO;
import com.viettel.core.entities.cms.AnswersQuestion;
 /**
   *  Mo ta muc dich cua lop (interface)
   *  @author: TOANTM1
   *  @version:  
   *  @since: 27/02/2014 - 11:34:02
   */
 public class AnswersQuestionMgrImpl implements AnswersQuestionMgr{ 
	@Autowired 
	AnswersQuestionDAO answersquestionDAO; 
 
 	/**@author TOANTM1
  	 * 27/02/2014 - 11:34:02
  	 * For: 
  	 * @description: 
  	 */
 	@Override 
	public AnswersQuestion getAnswersQuestionById(Integer id) throws BusinessException { 
		try { 
			return  answersquestionDAO.getAnswersQuestionById(id); 
		} catch (DataAccessException e) { 
			throw new BusinessException(e); 
		} 
	} 
 
 	/**@author TOANTM1
  	 * 27/02/2014 - 11:34:02
  	 * For: 
  	 * @description: 
  	 */
 	@Override 
	public AnswersQuestion createAnswersQuestion(AnswersQuestion answersquestion) throws BusinessException { 
		try { 
			return answersquestionDAO.createAnswersQuestion(answersquestion); 
		} catch (DataAccessException e) { 
			throw new BusinessException(e); 
		} 
	} 
 
 	/**@author TOANTM1
  	 * 27/02/2014 - 11:34:02
  	 * For: 
  	 * @description: 
  	 */
 	@Override 
	public void updateAnswersQuestion(AnswersQuestion answersquestion) throws BusinessException { 
		try { 
			answersquestionDAO.updateAnswersQuestion(answersquestion); 
		} catch (DataAccessException e) {	 
			throw new BusinessException(e); 
		} 
	} 
 
 	/**@author TOANTM1
  	 * 27/02/2014 - 11:34:02
  	 * For: 
  	 * @description: 
  	 */
 	@Override 
	public void deleteAnswersQuestion(AnswersQuestion answersquestion) throws BusinessException { 
		try { 
			answersquestionDAO.deleteAnswersQuestion(answersquestion); 
		} catch (DataAccessException e) { 
			throw new BusinessException(e); 
		} 
	} 
} 
